package com.yan.design.two.structure.s2;

/**
 * 2. 桥接模式
 *      电脑 - 维度
 * @author shengren.yan
 * @create 2022-07-24
 */
public abstract class Computer {

    // 组合 品牌
    protected Brand brand;

    public Computer(Brand b){
        super();
        this.brand = b;
    }

    protected void info(){
        this.brand.info();
    }

    protected void open(){
        this.brand.open();
    }

    public void close(){
        brand.close();
    }


}

//class Desktop extends Computer{
//
//
//}
